package com.netintech.project.system.videoPacketLossRate.service;


import java.io.FileNotFoundException;
import java.io.IOException;

public interface LossRateService {

    /**
     * 根据指定的rtsp地址、分析时间间隔、tcp或者udp方式，分析丢包率
     * @param seconds
     * @param transportType
     * @return
     * @throws IOException
     * @throws InterruptedException
     */
    String execute(Integer seconds,String transportType,String rtspUrl) throws IOException, InterruptedException;


    /**
     * 从excel读取设备rtsp地址等信息，指定分析时间间隔，分析丢包率，写回excel
     * @param seconds
     * @param transportType
     * @return
     * @throws IOException
     * @throws InterruptedException
     */
    void executeFromExcel(Integer seconds,String transportType) throws Exception;


    /**
     * 从数据库获取设备rtsp地址等信息，指定分析时间间隔，分析丢包率，写回excel
     * @param seconds
     * @param transportType
     * @return
     * @throws IOException
     * @throws InterruptedException
     */
    void executeFromDb(Integer seconds,String transportType) throws InterruptedException;

    void excelInit(Exception e);

    void dbInit(Exception e);
}
